<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
    xmlns:core="http://typo3.org/ns/TYPO3/CMS/Core/ViewHelpers"
    xmlns:be="http://typo3.org/ns/TYPO3/CMS/Backend/ViewHelpers"
    xmlns:bu="http://typo3.org/ns/TYPO3/CMS/Beuser/ViewHelpers">

<f:section name="list_row">
<tr>
    <td>
        <a href="#" class="t3js-contextmenutrigger" data-table="be_users" data-uid="{backendUser.uid}" title="{f:if(condition: '{backendUser.description}', then: '{backendUser.description} ')}(id={backendUser.uid})">
            <be:avatar backendUser="{backendUser.uid}" showIcon="TRUE" />
        </a>
    </td>
    <td class="col-title">
        <be:link.editRecord table="be_users" uid="{backendUser.uid}" title="edit">
            <b>{backendUser.userName}</b>
        </be:link.editRecord>
        <f:if condition="{onlineBackendUsers.{backendUser.uid}}">
            <span class="label label-success"><f:translate key="online" /></span>
        </f:if>
        <br />
        <f:if condition="{backendUser.realName}">
            <be:link.editRecord table="be_users" uid="{backendUser.uid}" title="edit">
                {backendUser.realName}
            </be:link.editRecord>
        </f:if>
    </td>
    <td>
        <f:if condition="{backendUser.lastLoginDateAndTime}">
            <f:then>
                <f:format.date format="{dateFormat} {timeFormat}">{backendUser.lastLoginDateAndTime}</f:format.date>
            </f:then>
            <f:else>
                <f:translate key="never" />
            </f:else>
        </f:if>
    </td>
    <td class="col-control">
        <div class="btn-group" role="group">
            <be:link.editRecord class="btn btn-default" table="be_users" uid="{backendUser.uid}" title="{f:translate(key:'edit')}">
                <core:icon identifier="actions-open" />
            </be:link.editRecord>
            <f:if condition="{backendUser.currentlyLoggedIn} == 1">
                <f:then>
                    <span class="btn btn-default disabled"><core:icon identifier="empty-empty" /></span>
                </f:then>
                <f:else>
                    <f:if condition="{backendUser.isDisabled} == 1">
                        <f:then>
                            <a class="btn btn-default" href="{be:moduleLink(route:'tce_db', query:'data[be_users][{backendUser.uid}][disable]=0', currentUrlParameterName:'redirect')}" title="{f:translate(key:'visibility.unhide')}"><core:icon identifier="actions-edit-unhide" /></a>
                        </f:then>
                        <f:else>
                            <a class="btn btn-default" href="{be:moduleLink(route:'tce_db', query:'data[be_users][{backendUser.uid}][disable]=1', currentUrlParameterName:'redirect')}" title="{f:translate(key:'visibility.hide')}"><core:icon identifier="actions-edit-hide" /></a>
                        </f:else>
                    </f:if>
                </f:else>
            </f:if>
            <f:if condition="{currentUserUid} == {backendUser.uid}">
                <f:then>
                    <span class="btn btn-default disabled"><core:icon identifier="empty-empty" /></span>
                </f:then>
                <f:else>
                    <a class="btn btn-default t3js-modal-trigger" href="{be:moduleLink(route:'tce_db', query:'cmd[be_users][{backendUser.uid}][delete]=1', currentUrlParameterName:'redirect')}"
                        title="{f:translate(key:'delete')}"
                        data-severity="warning"
                        data-title="{f:translate(key:'LLL:EXT:backend/Resources/Private/Language/locallang_alt_doc.xlf:label.confirm.delete_record.title')}"
                        data-content="{f:translate(key:'confirm',arguments:'{0:backendUser.userName}')}"
                        data-button-close-text="{f:translate(key:'LLL:EXT:core/Resources/Private/Language/locallang_common.xlf:cancel')}">
                        <core:icon identifier="actions-edit-delete" />
                    </a>
                </f:else>
            </f:if>
        </div>
        <div class="btn-group" role="group">
            <f:if condition="{backendUser.passwordResetEnabled}">
                <f:then>
                    <f:link.action
                        class="btn btn-default t3js-modal-trigger"
                        action="initiatePasswordReset"
                        arguments="{user: backendUser.uid}"
                        title="{f:translate(key: 'resetPassword.label')}"
                        data="{severity: 'warning', title: '{f:translate(key: \'resetPassword.confirmation.header\')}', content: '{f:translate(key: \'resetPassword.confirmation.text\', arguments: {0: \'{backendUser.email}\'})}', button-close-text: '{f:translate(key: \'LLL:EXT:core/Resources/Private/Language/locallang_common.xlf:cancel\')}'}">
                        <core:icon identifier="actions-edit-undo" />
                    </f:link.action>
                </f:then>
                <f:else>
                    <span class="btn btn-default disabled"><core:icon identifier="empty-empty" /></span>
                </f:else>
            </f:if>
            <f:link.action action="show" arguments="{uid: backendUser.uid}" class="btn btn-default" title="{f:translate(key: 'details')}">
                <core:icon identifier="actions-system-options-view" size="small"/>
            </f:link.action>
            <a class="btn btn-default" href="#" title="{f:translate(key:'info')}" data-dispatch-action="TYPO3.InfoWindow.showItem" data-dispatch-args-list="be_users,{backendUser.uid}">
                <core:icon identifier="actions-document-info" />
            </a>
        </div>
        <div class="btn-group" role="group">
            <f:if condition="{compareUserUidList.{backendUser.uid}}">
                <f:then>
                    <f:link.action action="removeFromCompareList" arguments="{uid: backendUser.uid}" class="btn btn-default" title="{f:translate(key: 'compare')}">
                        <core:icon identifier="actions-remove" size="small"/>
                        <f:translate key="compare" />
                    </f:link.action>
                </f:then>
                <f:else>
                    <f:link.action action="addToCompareList" arguments="{uid: backendUser.uid}" class="btn btn-default" title="{f:translate(key: 'compare')}">
                        <core:icon identifier="actions-add" size="small"/> <f:translate key="compare" />
                    </f:link.action>
                </f:else>
            </f:if>
            <bu:SwitchUser backendUser="{backendUser}" />
        </div>
    </td>
</tr>
</f:section>
</html>
